package com.code.user.social;

import org.springframework.security.oauth2.common.OAuth2AccessToken;

/**
 * Created by IntelliJ IDEA.
 *
 * @author: Yan
 * @date: 2023/4/6
 */
public interface SocialHandler {

    /**
     * 构建请求到第三方登录页地址
     * @return
     */
    String buildLoginUrl();

    /**
     * 构建处理回调接口返回的数据，然后生成token
     * @param code
     * @param state
     * @return
     */
    OAuth2AccessToken buildOAuth2AccessToken(String code, String state);

}
